]> dgit.raspbian.org Git - gnome-shell.git/commit
workspaceAnimation: Perform a grab during workspace switch gestures
authorCarlos Garnacho <carlosg@gnome.org>
Tue, 30 Dec 2025 12:24:41 +0000 (13:24 +0100)
committerMarge Bot <marge-bot@gnome.org>
Mon, 19 Jan 2026 16:28:44 +0000 (16:28 +0000)
commitc336fb4264afd295b92be9aa4d599976a5885b83
treec35bc6d8b35b6b782347cd5b5fa750075f20d662
parent2f8dc0cec6e5d7c5f87b710408963a3ac058e1d3
workspaceAnimation: Perform a grab during workspace switch gestures

Currently, the mechanism to reclaim touch input from clients and into
the gesture is somewhat indirect:
- The swipeTracker gesture(s) will enter in a recognized state
- The MetaGestureTracker will notice the recognized state on a gesture
  set up in the ClutterStage actor, and emit META_SEQUENCE_ACCEPTED
  on the sequence
- The core will notice the sequence being accepted and call
  meta_display_cancel_touch()/meta_wayland_touch_cancel()
- This eventually results in wl_touch.cancel on the affected client(s)

This is a bit too convoluted and special cased, so claim input using
a more traditional way: Using a Clutter grab. This will also result in
touch being cancelled on the Wayland side. This will happen along with
other input, but that's actually a consistence improvemente, since the
other method would not prevent other input (e.g. pointer) while the
workspace gesture is ongoing. This results in glitchy behavior if
multiple input devices are used simultaneously.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/4020>
js/ui/workspaceAnimation.js